<!-- 单个客户详情 -->


<!DOCTYPE HTML>
<html xmlns:th="http://www.thymeleaf.org">
<div th:replace="~{fragment/headFragment :: head}"></div>
<body class="cbp-spmenu-push modal-open">
<div class="main-content">
    <div th:replace="~{fragment/left-border :: left}"></div>

    <div th:replace="~{fragment/header :: header}"></div>

    <div id="page-wrapper" style="padding-top:5em;" >
        <div class="main-page">

<!--            <div class="col-md-4 modal-grids">-->
<!--                <button type="button" class="btn btn-primary btn-lg" data-toggle="modal" data-target="#gridSystemModal">Demo modal </button>-->
                <div class="modal fade"  th:classappend="${(state eq 3)?'in':''}" id="gridSystemModal" tabindex="-1" role="dialog" aria-labelledby="gridSystemModalLabel"  th:attr="aria-hidden=(${(state eq 3)?'false':'true'})" th:styleappend="${(state eq 3)?'display: block;':'display: none;'}">
                    <div class="modal-dialog" role="document">
                        <div class="modal-content">
                            <div class="modal-header">
                                <a th:href="@{/customerInfo/getOne(id=${customer.id},state=-1,current=${#request.getParameter('current')})}">
                                    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                                </a>
                                <h4 class="modal-title" id="gridSystemModalLabel">Modal title</h4>
                            </div>
                            <div class="modal-body">
                                <div class="row" th:text="'是否将用户'+${customer.getRealname()}+'移出黑名单？'">
                                </div>
                            </div>

                            <div class="modal-footer">
                                <a th:href="@{/customerInfo/getOne(id=${customer.id},state=-1,current=${#request.getParameter('current')})}">
                                    <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
                                </a>
                                <a th:href="@{/customerInfo/blackListOperate(id=${customer.id},state=3,current=${#request.getParameter('current')})}">
                                    <button type="button" class="btn btn-primary">确认移出</button>
                                </a>
                            </div>
                        </div><!-- /.modal-content -->
                    </div><!-- /.modal-dialog -->
                </div><!-- /.modal -->
<!--            </div>-->
<!--            <div class="col-md-4 modal-grids">-->

<!--                <button type="button" class="btn btn-primary" data-toggle="modal" data-target=".bs-example-modal-sm">Small modal</button>-->
                <div class="modal fade bs-example-modal-sm" th:classappend="${(state eq 1)?'in':''}" tabindex="-1" role="dialog" aria-labelledby="mySmallModalLabel" th:attr="aria-hidden=(${(state eq 1)?'false':'true'})" th:styleappend="${(state eq 1)?'display: block;':'display: none;'}">
                    <div class="modal-dialog modal-sm">
                        <div class="modal-content">
                            <div class="modal-header">
                                <a th:href="@{/customerInfo/getOne(id=${customer.id},state=-1,current=${#request.getParameter('current')})}">
                                    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
                                </a>
                                <h4 class="modal-title" id="mySmallModalLabel">Message</h4>
                            </div>
                            <div class="modal-body" th:text="'已成功将用户'+${customer.getRealname()}+'拉入黑名单'">
                            </div>
                        </div>
                    </div>
                </div>
<!--            </div>-->




            <div class="elements  row">

                <div class="col-md-4 profile widget-shadow">
                    <div>
                        <a th:href="@{/customerInfo/index(value='',current=${#request.getParameter('current')},size=5)}"><h4 class="title3"><<  Profile</h4></a>
                        <a th:href="@{/customerInfo/blackListOperate(id=${#request.getParameter('id')},state=${state},current=${#request.getParameter('current')})}">
                            <img th:src="${((state eq 2) or (state eq 3))?'images/table.png':'images/lahei.png'}" style="position: absolute;right: 10px;top:10px;height:32px;cursor: pointer;"></div>
                        </a>
                    <div class="profile-top">
<!--                        <img src="images/img1.png" alt="">-->
                        <img src="images/customer.png" alt="" style="width: 100px;">
                        <h4 th:text="${customer.getCustomername()}"></h4>
                        <h5 th:text="${customer.getState()}+'  '+${customer.getChannel()}"></h5>
                    </div>
                    <div class="profile-text">
                        <div class="profile-row">
                            <div class="profile-left">
                                <i class="fa fa-envelope profile-icon"></i>
                            </div>
                            <div class="profile-right">
                                <h4 th:text="${customer.getEmail()}"></h4>
                                <p>Email</p>
                            </div>
                            <div class="clearfix"> </div>
                        </div>
                        <div class="profile-row row-middle">
                            <div class="profile-left">
                                <i class="fa fa-mobile profile-icon"></i>
                            </div>
                            <div class="profile-right">
                                <h4 th:text="${customer.getPhone()}"></h4>
                                <p>Contact Number</p>
                            </div>
                            <div class="clearfix"> </div>
                        </div>
                        <div class="profile-row row-middle">
                            <div class="profile-left">
                                <i class="fa fa-facebook profile-icon"></i>
                            </div>
                            <div class="profile-right">
                                <h4 th:text="${customer.getCompany()}"></h4>
                                <p>Company</p>
                            </div>
                            <div class="clearfix"> </div>
                        </div>
                        <div class="profile-row">
                            <div class="profile-left">
                                <i class="fa fa-facebook profile-icon"></i>
                            </div>
                            <div class="profile-right">
                                <h4 th:text="${customer.getAddress()}"></h4>
                                <p>Address</p>
                            </div>
                            <div class="clearfix"> </div>
                        </div>
                    </div>
                    <div class="profile-btm">
                        <ul>
                            <li>
                                <h4 th:text="${customer.getRealname()}"></h4>
                                <h5>RealName</h5>
                            </li>
                            <li>
                                <h4 th:text="${customer.getLevel()}"></h4>
                                <h5>Level</h5>
                            </li>
                            <li>
                                <h4 th:text="${count}"></h4>
                                <h5><a th:href="@{/customerInfo/getCustomerOrder(id=${customer.id},value='',current=${#request.getParameter('current')},current1=1,size=5)}">工单 >></a></h5>
                            </li>
                        </ul>
                    </div>
                </div>

                <div class="col-md-4 profile widget-shadow chat-mdl-grid" style="width:50%;">
                    <div th:if="${session.NAME}ne '??'">
                        <h4 style="color: white;text-align: center;margin-bottom:10px;"  class="title3" th:text="${session.NAME}" ></h4>
                    </div>
                    <div th:if="${session.NAME}eq '??'">
                        <h4 style="color: white;text-align: center;margin-bottom:10px;" class="title3" th:text="${session.name}"></h4>
                    </div>

                    <tr class="info" th:each="cs,rowInfo : ${messageList2}">


                        <div class="activity-row activity-row1 right" style="padding-left: 38px;" th:if="${cs.getFromvisitor()}">
                            <div class="col-xs-3 activity-img"><img src="images/liaotian.png" class="img-responsive" alt="" style="text-align: right"></div>
                            <div class="col-xs-9 activity-img1">
                                <div class="activity-desc-sub">
                                    <p th:text="${cs.getContent()}"></p>
                                    <span style="color: #03a9f4" th:text="${cs.getSendtime()}"></span>



                                </div>
                            </div>
                            <div class="clearfix"> </div>
                        </div>



                        <div class="activity-row activity-row1 activity-left" style="padding-left: 38px;" th:if="${!(cs.getFromvisitor())}">

                            <div class="col-xs-9 activity-img2" >
                                <div class="activity-desc-sub1">
                                    <p th:text="${cs.getContent()}"></p>
                                    <span style="color: #03a9f4" th:text="${cs.getSendtime()}"></span>



                                </div>
                            </div>
                            <div class="col-xs-3 activity-img"><img th:src="@{${session.cs.getHeadimg()}}" style="height: 60px;" class="img-responsive img-circle" alt=""></div>
                            <div class="clearfix"> </div>
                        </div>


                    </tr>

                    <div class="chat-bottom">

                        <form action="/customerInfo/insertmessage"  method="get">
                            <input type="text" name="cusSerID" style="display: none" th:value="${session.cusSerID}">
                            <input type="text" name="cusID" style="display: none" th:value="${session.cusID}">
                            <input type="text" name="current" style="display: none" th:value="${#request.getParameter('current')}">
                            <input type="text" placeholder="Reply" required="" name="value">
                            <div style="text-align: right;margin-top: 10px;"><input  type="submit" value="发送" ></div>
                        </form>
                    </div>
                </div>
            </div>


        </div>
        <!-- Classie -->
        <script src="js/classie.js"></script>
        <script>
            var menuLeft = document.getElementById( 'cbp-spmenu-s1' ),
                showLeftPush = document.getElementById( 'showLeftPush' ),
                body = document.body;

            showLeftPush.onclick = function() {
                classie.toggle( this, 'active' );
                classie.toggle( body, 'cbp-spmenu-push-toright' );
                classie.toggle( menuLeft, 'cbp-spmenu-open' );
                disableOther( 'showLeftPush' );
            };

            function disableOther( button ) {
                if( button !== 'showLeftPush' ) {
                    classie.toggle( showLeftPush, 'disabled' );
                }
            }
        </script>
        <!--scrolling js-->
        <script src="js/jquery.nicescroll.js"></script>
        <script src="js/scripts.js"></script>
        <!--//scrolling js-->
        <!-- Bootstrap Core JavaScript -->
        <script src="js/bootstrap.js"> </script>
</body>
</html>